/*
 * c_registro.h
 *
 *  Created on: 27 Apr 2010
 *      Author: osky
 */

#include "../CapaFisica/c_bloque.h"

#ifndef C_REGISTRO_H_
#define C_REGISTRO_H_


class c_registro

    {
    // ********************************** //
    private:

        unsigned int clave;
        unsigned int largodata;
        void *data;

    // ********************************** //

    public:
    /* Constructor */

        c_registro ( int c_clave, unsigned int c_largodata, void* c_data);

        c_registro ();

        void set_registro ( unsigned int s_clave, unsigned int s_largodata, void* s_data);

        void get_registro ( unsigned int &g_clave,  unsigned int &g_largodata, void* &g_data);
    
        int copiar (c_registro *reg_b);

        int serializar( c_bloque* membuffer);

        int deserializar( c_bloque* membuffer);

        unsigned int largo_reg ();

        unsigned int get_clave();
    
        char* get_data ();

    };


#endif /* C_REGISTRO_H_ */

